<%@page contentType="text/html; charset=utf-8" %>
<%@ include file="/commons/taglibs.jsp"%>
<html>
<head>
<title>Insert title here</title>
<link href="${ctx}/styles/aux_window.css" rel="stylesheet" type="text/css">
<%@include file="/commons/validation.jsp" %>
<script type="text/javascript">
	<c:if test="${!empty isEdit}">
		parent.windowOption.setButtonUsed(); //设置按钮可用
		parent.windowOption.flushMain(); //刷新列表
		parent.windowOption.close_window_withoutCondition();
	</c:if>
	var oldName = "";
	function submitForm(){
		var flag = document.forms[0].fireEvent("onSubmit");
		if(flag){
			document.forms[0].submit();
		}else{
			parent.windowOption.setButtonUsed(); //设置按钮可用
		}
	}
	function allowClose(){
		return document.getElementById("name").value == oldName;
	}
	function init(){
		oldName = document.getElementById("name").value;
		<c:if test="${! empty isSave}">
			parent.windowOption.setButtonUsed(); //设置按钮可用
			parent.tabOption.setTabEnable(); //设置其他tab可用
			parent.windowOption.flushMain(); //刷新列表
		</c:if>
	}
</script>
</head>
<body onload="init();">
<form action="${ctx}/house_projectAction.do?method=${empty is_Project_Edit ?'addBase' : 'editBase'}" method="post" class="required-validate">
	<input type="hidden" name="areaId" value="${areaId}">
	<input id="isSave" type="hidden" name="isSave" value="">
	<input id="isEdit" type="hidden" name="isEdit" value="">
    <div id="tab_Search" style="height:387px;">
      <table width="100%" border="0" cellpadding="0" cellspacing="0" id="tab_subMenu1">
        <tr>
          <td><table width="100%" border="0" align="center" cellpadding="5" cellspacing="0">
              <tr>
                <td><table width="100%" border="0" cellpadding="0" cellspacing="1" class="aux_intable_color">
                    <tr>
                      <td class="aux_intable_td1">${key.project_name}</td>
                      <td class="aux_intable_require">
                      	<input id="name" name="name" type="text"
                      			class="inputtext required validate-ajax"
                      			validateUrl="${ctx}/house_projectAction.do?method=validateProjectName&projectId=${projectVO.keyword}&isValidation=isValidation"
                      			validateMessage="${key.error_project_name}"
                      			size="16" value="${projectVO.name}"
                      			maxlength="100">
                      </td>
                    </tr>
                </table></td>
              </tr>
          </table></td>
        </tr>
      </table>
     </div>
</form>
</body>
</html>